public class EnumSwitch {
    public enum Spiciness {
        NOT, MILD, MEDIUM, HOT, FLAMING;
    }

    Spiciness degree;

    public EnumSwitch(Spiciness degree) {
        this.degree = degree;
    }

    public void describe() {
        switch (degree) {
            case NOT:
                System.out.println("not spicy at all");
                break;
            case MILD:
            case MEDIUM:
                System.out.println("a little hot");
                break;
            case HOT:
            case FLAMING:
            default:
                System.out.println("maybe too hot");
        }
    }

    public static void main(String[] args) {
        EnumSwitch plain = new EnumSwitch(Spiciness.NOT),
                greenChile = new EnumSwitch(Spiciness.MEDIUM),
                jalapeno = new EnumSwitch(Spiciness.HOT);
        plain.describe();
        greenChile.describe();
        jalapeno.describe();
    }

}
